import {$get,$post,$put,$delete} from './request'
//查找所有的会议
export const $meetingSearch = async (params)=>{
    //  
    let data = await $get('/Meeting/getAllList', params)
    //console.log(data,"meetingSearch")
    return data;

}
//查找参加某个会议的所有用户，即查询joinmeeting表
export const $meetingPartSearch = async (params)=>{
    //
    console.log(params,"meetingPartSearch")
    let data = await $post('/Meeting/getPartList', params)
    //console.log(data,"meetingSearch")
    return data;
}
//查找参加某个会议的所有用户ID
export const $meetingPartSearchOnlyUserId = async (params)=>{
    //
    console.log(params,"meetingPartSearch")
    let data = await $post('/Meeting/getPartListOnlyUserId', params)
    //console.log(data,"meetingSearch")
    return data;
}

//查找用户主持的会议
export const $myHostMeetingSearch = async (params)=>{ 
    let data = await $post('/Meeting/getHostList', params)
    //console.log(data,"meetingSearch")
    return data;
}
//查找用户参加的会议
export const $myJoinMeetingSearch = async (params)=>{ 
    let data = await $post('/Meeting/getJoinList', params)
    //console.log(data,"meetingSearch")
    return data;
}
export const $PartSearch = async (params)=>{ 
    let data = await $get('/User/getList', params)
    console.log(data,"PartSearch")
    return data;
}

export const $MeetingRoomgetOkList = async (params)=>{ 
    let data = await $post('/MeetingRoom/getOkList', params)
    console.log(data,"PartSearch")
    return data;
}

//添加会议
export const $meetingAdd = async (params)=>{
    //
    let data = await $post('/Meeting/newCon', params)
    console.log(data,"meetingAdd")
    return data;

}
//更新会议
export const $meetingUpdate = async (params)=>{
    //console.log(params,"params")
    console.log(params,"params")
    let data = await $put('/Meeting/UpdateMeeting', params)
    console.log(data,"meetingUpdate")
    return data;

}
//删除会议
export const $meetingDelete = async (params)=>{
    //
    console.log(params,"params")
    let data = await $put('/Meeting/DeleteMeeting', params)
    
    console.log(data,"meetingDelete")
    return data;

}